﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Pages/Default.Master" AutoEventWireup="true" CodeBehind="ManagedFileList.aspx.cs" Inherits="Fynd.Hermes.Web.Pages.ManagedFileList" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolderHtmlHead" runat="server">
    
    <script type="text/javascript">
        $(document).ready(function () {
            $("#datepicker").datepicker({
                altField: "#textDate",
                dateFormat: "yy-mm-dd",
                defaultDate: '<%=DateFilterValue.ToString("yyyy-MM-dd") %>',
                onSelect: function (dateText, inst) {
                    location.href = "ManagedFileList.aspx?date=" + dateText;
                }
            });
        });
  </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolderMain" runat="server">
    <p>
        <a href="ManagedFileUpload.aspx">上传APK</a>
    </p>
    <hr />
    <table>
        <tr style="vertical-align:top;">
            <td>
        
        
                <p>
                    按日期筛选<input id="textDate" name="Date" type="text" value="" />
                    <span id="datepicker"></span>
        
                </p>
            </td>
            <td style="width:100%;">
                <div class="ui-widget-content">
<%
    if (ResultList.Count <= 0)
    {
%>
        <p class="ui-state-highlight">
            <strong><%=DateFilterValue.ToString("yyyy-MM-dd") %>没有上传任何文件。</strong>
        </p>
<%
    }
    else
    {
%>
    <table style="width:100%;">
        <tr>
            <th>路径</th>
            <th>上传者</th>
            <th>上传时间</th>
        </tr>
<%
        foreach (Fynd.Hermes.Web.Objects.ManagedFile aFile in ResultList)
        {    
%>
                <tr>
                    <td>
                        <a href="ManagedFileDownload.aspx?id=<%=aFile.Id %>"><%=aFile.RelativePath%></a>
                    </td>
                    <td><%=aFile.UploaderTrueName%></td>
                    <td><%=aFile.CreatedDate%></td>
                </tr>
<%
                     
        } 
%>
    </table>
<%
    } 
%>
                </div>
            </td>
        </tr>
    </table>
</asp:Content>
